import request from '@/utils/request'
export function getSuggestion(keyword) {
  return request({
    method: 'get',
    url: '/v1_0/suggestion',
    params: {
      q: keyword
    }
  })
}
/**
 * 获取搜索结果
 * @param {*} keyword 搜索关键字
 * @param {*} page 当前页
 * @returns
 */
export function getSearch(keyword, page = 1) {
  return request({
    method: 'get',
    url: '/v1_0/search',
    params: {
      q: keyword,
      page,
      per_page: 10
    }
  })
}
